home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / networking / terms / kermit / b / ikcker.ins < prev    next >
Encoding:
Text File  |  1993-06-29  |  31.4 KB  |  814 lines

  1. IBM System/370 VM/CMS Kermit 4.2.n Installation Instructions
  2.                      (1993 June)
  3.  
  4. The following instructions, aside from steps 1, 7, and 8, are collected
  5. into an EXEC for ease of application.  See the end of this file.
  6.  
  7.                   * * Installation Procedure * *
  8.  
  9. 1) Get the necessary files from the Kermit distribution tape or from
  10.    BITNET KERMSRV or elsewhere onto your A disk.  Be sure you have
  11.    plenty of disk space for the installation (required: about 10 MB,
  12.    including scratch space and the executables).  Note that many of the
  13.    files are generic for Kermit-370 and may already be available from a
  14.    local MVS/TSO site.  As distributed by Columbia, the files are named
  15.    as follows, all with prefix IKC or IK0 (I K Zero):
  16.  
  17.    IKCAUX.CMD  Sample EXEC's PC, KERMAIL, etc.
  18.    IKCBOO.ASM  Assembler source for Kermit bootstrap program
  19.    IKCFIX.EXEC Repair kit for mail gateway damage
  20.    IKCKER.BWR  A "beware" file, listing known bugs, problems, and fixes
  21.    IKCKER.DOC  CMS Kermit User Guide, plain text
  22.    IKCKER.HLP  Kermit-CMS help file, CMS HELP (Script) format
  23.    IKCKER.INS  Kermit-CMS installation instructions (this file)
  24.    IKCKER.UPD  Updates for CMS version of Kermit-370
  25.    IKCMAC.ASM  Assembler source for CMS-specific macros
  26.    IKCUTL.ASM  Assembler source for CMS-specific routines
  27.    IKCXA.UPD   Further updates for CMS/XA variant of Kermit-370
  28.    IK0CMD.ASM  Assembler source for command handler
  29.    IK0COM.ASM  Assembler source for global code
  30.    IK0DEF.ASM  Assembler source for parameter definitions
  31.    IK0DOC.ASM  Assembler source with brief history
  32.    IK0KAN.ASM  Assembler source for Kanji character translation
  33.    IK0KER.BWR  Another "beware" file, with generic entries
  34.    IK0MAC.ASM  Assembler source for generic Kermit macros
  35.    IK0MAI.ASM  Assembler source for storage initialization
  36.    IK0PRO.ASM  Assembler source for generic routines
  37.  
  38.    The following files are not necessary for installation, but may be of
  39.    some interest.
  40.  
  41.    IKCACT.ASM  Assembler source for sample accounting exit routine
  42.    IKCGUP.ASM  Assembler source for CMS-specific part of GUPI
  43.    IKCHDR.MSS  Scribe source for producing IKCKER.DOC
  44.    IKCKER.ANN  Text of Kermit-CMS announcement for current version
  45.    IKCKER.LPT  Same as IKCKER.DOC, but with carriage control in col 1
  46.    IKCKER.MSS  Scribe source for CMS part of IKCKER.DOC
  47.    IKCKER.PS   PostScript equivalent of IKCKER.DOC
  48.    IK0AAA.HLP  Kermit-370 implementation notes, supported environments
  49.    IK0CON.HLP  Notes on supporting other terminal controllers
  50.    IK0GUP.ASM  Assembler source for generic update program GUPI
  51.    IK0KER.ANN  Text of generic Kermit-370 4.2 announcement
  52.    IK0KER.MSS  Scribe source for generic part of IKCKER.DOC
  53.    IK0KER.UPD  Update history for Kermit-370
  54.    IK0POR.HLP  Notes on porting Kermit-370 to other systems
  55.    IK0VER.FOR  Comparison program for generating update decks
  56.  
  57. 2) Rename and reformat, if necessary, the source files on the A disk.
  58.    If you received the program from Columbia on tape or over a network,
  59.    the assembler source filenames are probably all IKxxxx and the
  60.    filetype ASM.  Logically, these are concatenated into a single file
  61.    called KERMIT ASSEMBLE (plus a few others).  This step is included in
  62.    the installation EXEC.  If you got the source files via e-mail, they
  63.    may have been reversibly corrupted by passage through various mail
  64.    gateways.  Use IKCFIX to repair such damage before proceeding with
  65.    the installation.
  66.  
  67. 3) Rename and reformat, if necessary, the help file.  The file IKCKER
  68.    HLP should generally be stored under the name KERMIT HELPCMS on the
  69.    same minidisk as the executable KERMIT MODULE, so that on-line help
  70.    will always be available and, in particular, so that the CMS HELP
  71.    KERMIT command and Kermit-CMS's HELP subcommand can find it.  This
  72.    step is also included in the EXEC, along with an option to install
  73.    help menus for CMS HELP KER.  You may, in fact, install *only* the
  74.    help files using the EXEC.
  75.  
  76.    The most comprehensive documentation is the pair of chapters of the
  77.    Kermit User Guide dealing with CMS, namely, the generic Kermit-370
  78.    chapter and the CMS-specific one.  These two are bundled together in
  79.    IKCKER.DOC and also in IKCKER.PS; the PostScript is suitable only for
  80.    printing, but the DOC file could also be stored wherever you keep
  81.    online documentation files, renamed appropriately.
  82.  
  83. 4) GLOBAL the necessary MACLIBs.  If you use VMFASM or VMFHASM or the
  84.    installation EXEC, the GLOBAL command is issued automatically.  Under
  85.    CMS releases 1 through 5.5 and 6, the MACLIBs are DMSSP, CMSLIB,
  86.    TSOMAC, and OSMACRO.  Under CMS 5.6 and 7 or higher, they are DMSOM,
  87.    DMSGPI, and OSMACRO.
  88.  
  89. 5) Assemble the source files:
  90.  
  91.    ASSEMBLE KERMIT         (or HASM, for CMS/SP 5.5 or later)
  92.    ASSEMBLE KERMBOOT       (Not necessary if using CMS/SP 4 or later)
  93.    ASSEMBLE KACCT          (if desired)
  94.  
  95.    Note, however, that the base source files are typically not the
  96.    latest version available.  Indeed, for releases 5.5 on up, you will
  97.    need to apply updates anyway.  IKCKER BWR has instructions on how to
  98.    do so, and the intallation EXEC automatically applies them, including
  99.    any local updates you have collected into a file called KERMIT LOCAL.
  100.  
  101. 6) There are 4 choices for installing the runnable modules, of which the
  102.    first (and best) is available starting with VM/SP Release 4.  This
  103.    choice is made automatically in the EXEC.
  104.  
  105.     a) With VM/SP Release 4 and later, create a dual-purpose module.
  106.  
  107.        LOAD KERMIT exits (RLDSAVE
  108.        GENMOD KERMIT
  109.  
  110.        where "exits" is the list of desired exit routines, such as
  111.        KACCT.
  112.  
  113.        The module created this way may be permanently pre-loaded by
  114.        the user as follows:
  115.  
  116.        NUCXLOAD KERMIT
  117.  
  118.        Such a pre-loaded module is always dropped when CMS encounters
  119.        an "ABEND" and it can also be removed (e.g., for replacement)
  120.        by issuing the following command:
  121.  
  122.        NUCXDROP KERMIT
  123.  
  124.     b) If your installation is below release 4 of VM/SP, you might just
  125.        install the Kermit-CMS program alone, to run in user memory.
  126.        This means it can't invoke some programs (see the DOC file for
  127.        more information about this).
  128.  
  129.        LOAD KERMIT
  130.        GENMOD KERMIT
  131.  
  132.     c) Install the Kermit bootstrap program alone.  This loads the
  133.        KERMIT TEXT object file into high memory, allowing it to invoke
  134.        any other program:
  135.  
  136.        LOAD KERMBOOT
  137.        GENMOD KERMIT
  138.  
  139.     d) Install both, to give users a choice:
  140.  
  141.        LOAD KERMIT
  142.        GENMOD KERMIT
  143.        LOAD KERMBOOT
  144.        GENMOD KERMBOOT
  145.  
  146.        Note: with VM/SP Release 5, KERMBOOT will no longer work, and
  147.        method (a) is the only recommended one.
  148.  
  149. 7) Install any desired auxilliary commands from IKCAUX CMD.  These are
  150.    sample EXEC's and may need to be tailored to your site.  The PC EXEC,
  151.    for example, assumes that the TERMINALR macro is defined in your PC
  152.    Kermit as "SERVER,CONNECT".  KERMAIL and KERMPRT must be set up
  153.    according to the local options and facilities for e-mail and print,
  154.    respectively.
  155.  
  156. 8)  To run Kermit-CMS, simply type "KERMIT" to the CMS system prompt.
  157.  
  158.                     * * Accounting Routine * *
  159.  
  160. If you wish to use the optional accounting exit routine with Kermit, you
  161. may do so by answering YES to that question from the installation EXEC.
  162. Before assembling KACCT, you should examine the source and customize it
  163. to your installation's needs, preferably by collecting your changes into
  164. an update file called IKCACT UPD, which will automatically be applied by
  165. the EXEC during installation.
  166.  
  167.                        * * Configuration * *
  168.  
  169. The IBM mainframe and its communications front end (3705, 7171, etc.)
  170. usually require that parity be used by any asynchronous ASCII device
  171. that wishes to communicate with it.  Exactly which kind of parity is
  172. site-dependent.  At Columbia, the 3705 requires Mark parity, and the
  173. 7171 requires Even parity.  Make sure your users know to use the
  174. appropriate parity setting, as well as any other settings required for
  175. IBM mainframe communication (see p.36-39 of the Kermit book).
  176.  
  177. For linemode transfers, the ASCII/EBCDIC translation in the front end is
  178. a key factor.  Kermit-CMS uses an ASCII/EBCDIC translation table which
  179. conforms to the one given in the IBM System/370 Reference Summary.  If
  180. your site's translation table is incompatible with the one Kermit uses,
  181. then enter the appropriate SET ATOE/ETOA/TATOE/TETOA subcommands in the
  182. SYSTEM KERMINI file.  As long as the system tables are invertible with
  183. respect to the printable ASCII characters (even if the A-to-E and E-to-A
  184. tables are not the inverses of each other), the SET subcommands can
  185. compensate.  However, if your system's ASCII/EBCDIC tables are not
  186. invertible, Kermit will not and cannot work; you must change your
  187. system's tables.  Refer to the generic Kermit-370 chapter of the User's
  188. Guide for a step-by-step customization procedure (see the section on
  189. translation tables).
  190.  
  191. Kermit-CMS operation is possible for most types of protocol converters;
  192. for best results, the converter should have a transparent mode.  If
  193. possible, be sure the converter is configured so that the graphics or
  194. transparent mode, whatever it is called, is enabled.  See IK0AAA.HLP for
  195. a list of front ends that are known to work and for a collection of
  196. notes and special warnings about some of them.  Some further
  197. installation details follow for specific devices.
  198.  
  199. When CMS Kermit is to be used with a 7171, make sure the 7171 is set
  200. up with its "keyboard lock delay" parameter set to 0.  Otherwise, the
  201. "terminal" will hang whenever CMS Kermit clears the screen.  This
  202. happens consistently when the parameter is set to 10, and not at all
  203. when set to 0.  For numbers in between, the higher the number, the
  204. more it happens.
  205.  
  206. There is another problem in the 7171 that can cause Kermit file
  207. transfers to abort after a flurry of retransmissions if XON/XOFF flow
  208. control is used by the receiving Kermit, or even by hardware in between
  209. the 7171 and the receiver.  To prevent this problem, set the 7171 flags
  210. so that XOFF is not a valid terminator of a transparent read.  See page
  211. 4-20 of "IBM 7171 Reference Manual and Programming Guide" (IBM
  212. publication number GA27-0021).
  213.  
  214. Kermit operation through a Renex protocol converter generally requires
  215. that type-ahead be turned off.
  216.  
  217. Kermit operation is possible through an IBM 3708 front end in two
  218. different configurations.  In the first, the terminal line must be set
  219. for either "protocol enveloping" or "dynamic" mode, and a session must
  220. be set for line-at-a-time operation for Kermit to work.  Other important
  221. details of the terminal configuration are: (1) the terminal must be
  222. specified as a TWX device, (2) the SSCP format should be set to USSNTO,
  223. (3) the terminal type ID should be set to 05, (4) the line should be set
  224. for 8, or possibly 7, data bits and 1 stop bit, (5) there should be no
  225. "read prompt", and (6) the so-called "alternate" translation table
  226. (number 3) should be selected.  Kermit-CMS may also need to be
  227. configured because some models of the 3708 (or some environments) do not
  228. pass the normal packet character SOH (code 1, CTRL-A).  A suitable
  229. substitute is HT (code 9, CTRL-I).  Alternatively, or additionally, it
  230. may help to set the 3708 "interface type" to 0.
  231.  
  232. The second possible 3708 configuration is "protocol conversion" mode and
  233. makes use of the FULLSCREEN type in Kermit, which is also suitable for
  234. many other kinds of protocol converter.  The basic setup consists of the
  235. following Kermit subcommands.
  236.  
  237.      .... mainframe .....        ....... PC .........
  238.      SET CONTROLLER FULL         set send start 62
  239.      SET RECEIVE START 62        set receive start 62
  240.      SET SEND START 62           set block b
  241.      SET BLOCK B                 set handshake none
  242.      SET HANDSHAKE 0
  243.  
  244. The 62's (Greater-than sign) may be replaced by some other decimal code
  245. for a printable character.  For best results, choose a character that
  246. seldom appears in the files you will be transferring.  In particular,
  247. avoid the Control, Eighth-bit, and Repeat prefixes.  Packet sizes are
  248. automatically restricted by Kermit-CMS, so you needn't set them unless
  249. conditions require packets shorter than the default (77).  Flow control
  250. may be needed to keep up with the data rate on some equipment.  The
  251. block check type should be set to "B" only if the protocol converter is
  252. overzealous in optimizing the data stream -- there are hazards in using
  253. any type other than "1" because of all the packet echoing.  Refer to
  254. IK0AAA.HLP for such details.  Note that the translation of characters
  255. imposes the same setup requirements on FULLSCREEN mode as on the
  256. traditional TTY mode (linemode).  See the DOC.
  257.  
  258. Kermit-CMS supports file transfers through the IBM 3174 AEA with B2 or
  259. higher microcode, but support is restricted to terminals with the ASCII
  260. Graphics capability in three ways that may require compensating
  261. installation:
  262.  
  263. a) The terminal type must be defined in the 3174 to support graphics
  264.    (only the built-in VT241 and Tektronix 4205 types plus suitable
  265.    user-defined terminal types).  IBM's AEA Reference describes how
  266.    to set up terminal tables.
  267.  
  268. b) The line must be defined without a Host Addressable Printer.
  269.  
  270. c) If the 3174 is owned by VTAM, the connection must be made with a
  271.    logmode that allows the Read Partition Query (such as M2SDLCQ).
  272.  
  273. -------- cut here for IKCINS EXEC (invoke for easy installation) ------
  274. &TRACE *
  275. *----------------------------------------------------------------------
  276. *                I K C I N S
  277. * Complete Kermit installation EXEC (including XEDIT macro, all in one)
  278. *   J.F.Chandler - 1992 August 18, revised Nov 10
  279. *   Expanded for Help menus 1993 March - thanks to Adam Kujawski
  280. *   More options: 1993 May
  281. * CMS / EXEC 2 -- Compatible with CMS releases 2 onward.
  282. * For an explanation of the operations in this EXEC, see IKCKER.INS and
  283. * IKCKER.BWR in the Kermit distribution.  Obtain the distribution files
  284. * (step 1 in "INS") before running this EXEC.
  285. * Installation requires about 10mb of disk work space.
  286. *
  287. * Optional customization: to create a PRINT file of the update details
  288. * and assemblies, change the definition of &PRKEEP at label -INSTALL
  289. * from NO to YES.  In the standard version of this EXEC, the PRINT file
  290. * is purged unless there are errors in the installation.
  291. *
  292. * Optional customization: to see the messages from UPDATE (each giving
  293. * the name of an update file as it is applied), change the definition
  294. * of &UPDMSG at label -INSTALL from NO to YES.  If you have local mods,
  295. * it may be helpful to see those messages, in case there is an message
  296. * among them.  Normally, this EXEC suppresses them all.
  297. *
  298. * Optional customization: to use extra options on the assembly step(s),
  299. * insert them into the definition of &ASMOPTS at label -INSTALL.  These
  300. * will be passed to the assembler "as is".
  301. *----------------------------------------------------------------------
  302. &IF &0 EQ IKCMENU &GOTO -MAKEMENU
  303. &IF &0 NE IKCFAN &GOTO -INSTALL
  304. *----------------- XEDIT MACRO TO FAN OUT UPDATE FILES ---------------
  305. *----------------- INTENDED TO BE INVOKED AS A PROFILE ---------------
  306.       &DISK = &8
  307.       &L = &LENGTH OF .&DISK
  308.       &IF &L NE 2 &IF &L NE 3 &DISK = O
  309.       &DISK5 = &CONCAT OF &DISK 5
  310.       &IF &L EQ 3 &DISK5 = &8
  311.       &COMMAND MAKEBUF
  312.       COMMAND PRESERVE
  313.       COMMAND SET RECFM F
  314.       COMMAND EXTRACT /FNAME/FTYPE/LINE
  315.       COMMAND SET MSGMODE OFF
  316.       COMMAND :1 SET ZONE 1 5
  317. -LOOP &LOOP -Z *
  318.         COMMAND STACK 1
  319.         &READ VARS * &FN &FT
  320.         &IF .&FT EQ . &GOTO -C
  321.         &COMMAND ERASE &FN &FT &DISK
  322.         COMMAND 1 PUT ;:READ; &FN &FT &DISK5
  323.         &IF &RC NE 2 &SKIP 2
  324.           COMMAND PUT * &FN &FT &DISK5
  325.           &GOTO -C
  326. -Z
  327. -C    COMMAND :&LINE.1 RESTORE
  328.       &COMMAND DROPBUF
  329.       COMMAND MSG &0 complete for &FNAME.1 &FTYPE.1
  330.       &STACK LIFO QUIT
  331.       &EXIT 0
  332. *
  333. *---------------------------------------------- INSTALL HELP MENU
  334. -MAKEMENU
  335. COMMAND EXTRACT /FMODE
  336. COMMAND :0 CASE M
  337. COMMAND :0 TRUNC *
  338. COMMAND :0 ZONE 1 6
  339. COMMAND SET STAY ON
  340. COMMAND SET MSGMODE OFF
  341. COMMAND 1 DEL /:READ /
  342. COMMAND REPEAT *
  343. COMMAND DELETE *
  344. COMMAND SET ARBCH ON $
  345. COMMAND SET ZONE 45 *
  346. COMMAND :1 C/$//*
  347. COMMAND SET ZONE 1 *
  348. COMMAND :1 C/:READ $ $/$/*
  349. COMMAND MACRO JOIN 25
  350. COMMAND REPEAT *
  351. COMMAND :1 / SET / 1 PUTD / SHOW / SETCOM HELPTASK &FMODE.1
  352. COMMAND XEDIT SETCOM HELPTASK &FMODE.1 (NOPROF
  353. COMMAND SET MSGMODE OFF
  354. &CALL -HELPPCH 33 list of SET parameters.
  355. COMMAND FILE
  356. &SETCOM25 = &STRING OF SETCOM TASK
  357. &SETCOM25 = &LEFT OF &SETCOM25 23
  358. COMMAND -1 I &SETCOM25 SET...
  359. &CALL -HELPPCH 25 list of subcommands.
  360. COMMAND /.../ C/ &BLANK / - List of SET subparameters/
  361. COMMAND SAVE KERCOM HELPTASK &FMODE.1
  362. COMMAND :1 DEL *
  363. &SETCOM25 = &LEFT OF KERMITCM 23
  364. COMMAND I &SETCOM25 KERMIT
  365. &SETCOM25 = &STRING OF KERCOM TASK
  366. &SETCOM25 = &LEFT OF &SETCOM25 23
  367. COMMAND I &SETCOM25 SUBCMDS...
  368. &CALL -HELPPCH 25 Help Menu.
  369. COMMAND /.../ C/ &BLANK / &BLANK - List of subcommands/
  370. &STACK FFILE KER HELPTASK &FMODE.1
  371. &EXIT
  372. -HELPPCH &MSG = &RANGE OF & 2 &N
  373. COMMAND ZONE &1 *
  374. COMMAND HEX ON
  375. COMMAND :0 C/ $/X'4A6C'/*
  376. COMMAND :0 I &BLANK
  377. COMMAND I &BLANK &BLANK This is the Kermit-CMS &MSG
  378. COMMAND I &BLANK &BLANK Place cursor on desired item and hit ENTER or PF1.
  379. COMMAND ADD 2
  380. &RETURN
  381. *
  382. *-------------------------------------------------- INSTALL KERMIT
  383. *
  384. -INSTALL
  385. *---------- Set to keep output print file or not...
  386. &PRKEEP = NO
  387. *---------- Set to suppress update application messages...
  388. &UPDMSG = NO
  389. *---------- Set to string of extra assembler options....
  390. &ASMOPTS = &STRING OF
  391. *--------------- INITIALIZE SOME VARIABLES (SET DEFAULTS)
  392. *  ALL THESE OPTIONS ARE CHECKED WITH THE INSTALLER
  393. *
  394. &STACK LIFO  NO  NO    NO   NO    YES   YES   YES  NO    NO   YES   YES
  395. &READ VARS  &XA &SFS &KANJ &NMAC &BASE &CLOB &FAN &ACT &BOOT &HELP &PDS
  396. &STACK LIFO  A   KERMIT HELPCMS   *   NO   NO       NO
  397. &READ VARS &DISK &CNTRL &HELPFT &SRC &LCL &MENU &HELPONLY
  398. *--------------------------------------- DECODE CMS LEVEL
  399. &COMMAND Q CMSLEVEL (LIFO
  400. &IF &RC NE 0 &STACK LIFO * * * *
  401. &READ VARS * * &CMSLEVEL
  402. &CMSLEVEL = &TRANS OF &CMSLEVEL ,
  403. &CMSLEVEL = &TRIM OF &CMSLEVEL
  404. * FOR CMS 7, CHECK IF HASM MISSING (OPTIONAL UNDER ESA 370 FEATURE)
  405. &COMMAND ESTATE HASM MODULE *
  406. &IF &RC NE 0 &IF .&CMSLEVEL GE .7 &CMSLEVEL = 7370
  407. &COMMAND ESTATE DMSGPI MACLIB S
  408. &XA2PLUS = &RC
  409. *    &LVL VALUES:                 2  3  4  5  6    7  8   9  10
  410. * NUCLEUS CMSLVL:                 -  6  7  8  8    9 10  10  11
  411. *
  412. &LVL = 1 + &POSITION OF &CMSLEVEL 3  4  5 5.5 5.6  6  7  7370 8
  413. &IF &LVL EQ 1 &IF &XA2PLUS EQ 0 &LVL = 8
  414. &XA     = &WORD OF           NO  NO NO NO YES YES NO YES NO  YES  &LVL
  415. &SFS    = &WORD OF           NO  NO NO NO  NO NO YES YES YES YES  &LVL
  416. &NMAC   = &WORD OF           NO  NO NO NO  NO YES NO YES YES YES  &LVL
  417. * NOTE: THE LIST OF "AVAILABLE" CMS LEVELS NEED NOT BE EXTENDED PAST 8
  418. * UNLESS NEW FUNCTIONS ARE ADDED TO KERMIT REQUIRING MACROS/DEFINITIONS
  419. * MISSING FROM THE CMS 7 AND 8 MACLIBS.
  420. *---------------------------------- DEDUCE CNTRL FILE NEEDED
  421. &IF &SFS EQ YES &CNTRL = KERMCMS6
  422. &IF &NMAC EQ YES &CNTRL = KERME370
  423. &IF &XA EQ NO &SKIP 3
  424.    &CNTRL = KERMXA
  425.    &IF &NMAC EQ YES &CNTRL = KERMXA21
  426.    &IF &SFS EQ YES &CNTRL = KERMESA
  427. *-------------------------------------- SPOOL PRINTER
  428. SENTRIES
  429. &L = &RC
  430. EXECIO * CP (LIFO ST QUERY VIRTUAL 00E
  431. SENTRIES
  432. &L = &RC - &L
  433. &LOOP 2 &L
  434.   &INFO2 = &INFO1
  435.   &READ STRING &INFO1
  436. &CHR = &PIECE OF &INFO1 9 1
  437. &SPCONT = 16
  438. &SPTO = 10
  439. &IF .&CHR NE . &SPTO = &SPTO + 1
  440. &SPCONT = &PIECE OF &INFO1 &SPCONT 6
  441. &SPTO = &PIECE OF &INFO2 &SPTO 12
  442. &COMMAND CP SPOOL 00E CONT TO *
  443. *---------------------------------- ANNOUNCE AND CONFIRM OPTIONS
  444. &COMMAND VMFCLEAR
  445. &PRINT &0 EXEC:
  446. &BEGPRINT -INFO
  447. installs Kermit on a working disk of your choice using distribution source and
  448. updates (assumed to be accessible).  The working disk should be at least 10MB.
  449. There must be enough virtual storage for updating and assembling (a few MB:
  450. depends on conditions).  Source files must be on a single disk (or on its R/O
  451. extensions), but other Kermit updates may be on any accessed disk.
  452.  
  453. To halt installation, enter 'STOP' at any prompt...
  454.  
  455. Before installing, search 'IKCKER BWR' for relevant optional mods.  Local
  456. updates should be listed in 'KERMIT AUXOPT' and be either already accessible
  457. or bundled into 'KERMIT LOCAL' with ':READ' separators.
  458.  
  459. -INFO
  460. &CALL -ASK HELPONLY  Install *only* the HELP file
  461. &IF &HELPONLY EQ NO &CALL -CHECK IKCKER BWR *
  462. &CALL -GETPARM SRC  mode  source filemode
  463. -ASKDISK
  464. &CALL -GETPARM DISK  disk  installation disk
  465. &DISK = &LEFT OF &DISK 1
  466. &DISK2 = &CONCAT OF &DISK 2
  467. &DISK5 = &CONCAT OF &DISK 5
  468. &TXTDSK = &DISK
  469. &COMMAND MAKEBUF
  470. &COMMAND LISTFILE KERMIT TEXT * (FIFO
  471. &IF &RC EQ 0 &READ VARS * * &TXTDSK
  472. &COMMAND DROPBUF
  473. &IF &HELPONLY EQ NO &IF &TXTDSK LT &DISK &GOTO -ERR5
  474. &COMMAND ESTATE KERMIT ASSEMBLE &DISK
  475. &BRC = &RC
  476. &IF &BRC NE 24 &IF &BRC NE 36 &IF &DISK NE * &SKIP 2
  477.   &PRINT Invalid filemode &DISK
  478.   &GOTO -ASKDISK
  479. &COMMAND MAKEBUF
  480. &COMMAND QUERY DISK &DISK (LIFO
  481. &READ VARS * * * &R/W * * &BLKSI * * &FBLK &TBLK
  482. &COMMAND DROPBUF
  483. &IF .&R/W EQ .R/W &SKIP 2
  484.    &PRINT Disk &DISK is not accessed R/W
  485.    &GOTO -ASKDISK
  486. &COMMAND ESTATE $KERMIT ASSEMBLE &DISK
  487. &URC = &RC
  488. &IF &HELPONLY EQ YES &GOTO -DISKOK
  489. &IF .&TBLK NE .- &GOTO -CHKSIZE
  490. &COMMAND MAKEBUF
  491. *                                       Get Filepool id
  492. &COMMAND QUERY ACCESSED &DISK ( LIFO
  493. &READ VARS * * * * &DIR
  494. &DIR = &TRANS OF &DIR : &BLANK
  495. &STACK LIFO &DIR
  496. &READ VARS &FP *
  497. &FP = &CONCAT OF &FP :
  498. *                                       Get available space
  499. &COMMAND QUERY LIMITS * &FP ( LIFO
  500. &READ VARS * * &TBLK &UBLK *
  501. &UBLK = &TRANS OF &UBLK - &BLANK
  502. &STACK LIFO &UBLK
  503. &READ VARS &UBLK *
  504. &COMMAND DROPBUF
  505. &FBLK = &TBLK - &UBLK
  506. -CHKSIZE
  507. &TSIZ = &MULT OF 0&BLKSI 0&TBLK
  508. &FSIZ = &MULT OF 0&BLKSI 0&FBLK
  509. &MINSIZ = 2000000
  510. &IF &BRC NE 0 &MINSIZ = &MINSIZ + 1000000
  511. &IF &URC NE 0 &MINSIZ = &MINSIZ + 1000000
  512. &IF &TSIZ GE 9000000 &IF &FSIZ GE &MINSIZ &SKIP 2
  513.    &PRINT Disk &DISK is too small or too full
  514.    &GOTO -ASKDISK
  515. -DISKOK
  516. &CALL -CHECK &0 EXEC *
  517. &COMMAND COPYFILE &0 EXEC &FM IKCFAN XEDIT &DISK5 (REPLACE TOLABEL -INSTALL
  518. &COMMAND COPYFILE &0 EXEC &FM IKCMENU XEDIT &DISK5 (REPLACE TOLABEL -INSTALL
  519. &IF &HELPONLY EQ YES &GOTO -MAKEHELP
  520. &X = &POSITION OF &CNTRL KERMIT KERMXA KERMXA21 KERMCMS6 KERMESA KERME370
  521. &X = &WORD OF             <5.5   5.5     5.6       6      >6     7(370)   &X
  522. &PRINT Control file '&CNTRL CNTRL' is suitable for CMS Rel. &X ...
  523. &CALL -GETPARM CNTRL  filename  control filename
  524. &IF .&NEW EQ . &SKIP 2
  525.   &X = 1 + &POSITION OF &CNTRL KERMIT KERMXA KERMXA21 KERMCMS6 KERMESA KERME370
  526.   &XA =     &WORD OF      NO     NO     YES    YES       NO      YES    NO   &X
  527. &COMMAND VMFCLEAR
  528. &IF &URC EQ 0 &CALL -ASK CLOB  Updated source already on disk &DISK - destroy it
  529. &IF &CLOB EQ NO &GOTO -ERR1
  530. &IF &BRC EQ 0 &CALL -ASK BASE  Base source already on disk &DISK - replace it
  531. *---------------------------- MAKE SURE ALL SOURCE FILES ARE PRESENT
  532. &IF &BASE EQ NO &GOTO -CHKEND
  533. &CALL -ASK KANJ  Include Kanji support
  534. &P1 = &STRING OF IK0DOC IK0MAC IKCMAC IK0DEF IK0MAI IK0COM IK0CMD IKCUTL
  535. &X = &STRING OF &P1 IK0PRO
  536. &IF &KANJ EQ YES &X = &STRING OF &P1 IK0KAN IK0PRO
  537. &STACK LIFO &X
  538. &READ ARGS
  539. &I = 0
  540. &LOOP 2 &N
  541.   &I = &I + 1
  542.   &CALL -CHECK &&I ASM &SRC
  543. -CHKEND
  544. &ASMCMD = ASSEMBLE
  545. &IF &XA EQ YES &ASMCMD = HASM
  546. &CALL -GETPARM ASMCMD  command  assemble command
  547. *------------------------------ MAKE SURE UPDATES ARE PRESENT
  548. &CALL -CHECK IKCKER UPD *
  549. &IF &XA EQ YES &CALL -CHECK IKCXA UPD *
  550. *-------------------------------------- MAKE SURE DISK IS DEFINED
  551. &COMMAND ESTATEW * * &DISK
  552. &IF &RC EQ 0 &SKIP 2
  553.   &COMMAND ESTATE * * &DISK
  554.   &IF &RC EQ 0 &GOTO -ERR2
  555. *
  556. *-------------- ************ S T E P   INS 2
  557. *
  558. *-------------------------------------- MAKE OPTIONAL ACCOUNTING EXIT
  559. &CALL -ASK ACT  Include optional accounting exit
  560. &IF &ACT EQ NO &GOTO -ACTEND
  561. &CALL -CHECK IKCACT ASM &SRC
  562. &COMMAND COPYFILE IKCACT ASM &FM KACCT ASSEMBLE &DISK5 (RECFM F LRECL 80 REP
  563. &COMMAND ESTATE IKCACT UPD &SRC
  564. &IF &RC NE 0 &GOTO -ACTEND
  565. &PRINT Updating KACCT
  566. &CALL -CHECK IKCACT UPD &SRC
  567. &COMMAND COPYFILE IKCACT UPD &FM KACCT UPDATE &DISK5 (RECFM F LRECL 80 REP
  568. &UPDOPTS = &STRING OF OUTMODE &DISK PRINT INC REP
  569. &COMMAND UPDATE KACCT ASSEMBLE &DISK5 KACCT UPDATE &DISK ( &UPDOPTS
  570. &UPDRC = &RC
  571. &COMMAND ERASE KACCT UPDATE &DISK
  572. &IF &UPDRC GT 12 &GOTO -ERR3
  573. -ACTEND
  574. *-------------------------------------- MAKE BASE SOURCE(S)
  575. ©OP = &STRING OF RECFM F LRECL 80 REP
  576. &IF &LVL GE 3 &GOTO -BOOTEND
  577. &BOOT = YES
  578. &CALL -ASK BOOT  Generate high-memory bootstrap
  579. &IF &BOOT EQ NO &GOTO -BOOTEND
  580. &PRINT **NOTE** KERMIT TEXT must be kept together with MODULE
  581. &CALL -CHECK IKCBOO ASM &SRC
  582. &COMMAND ESTATE KERMBOOT ASSEMBLE &DISK
  583. &IF &RC NE 0 &SKIP 1
  584.  &IF &BASE EQ NO &SKIP 1
  585.   &COMMAND COPYFILE IKCBOO ASM &FM KERMBOOT ASSEMBLE &DISK5 ( ©OP
  586. -BOOTEND
  587. &IF &BASE EQ NO &GOTO -MAKEND
  588. &PRINT Merging base source
  589. &I = 0
  590. &LOOP 4 &N
  591.   &I = &I + 1
  592.   &CALL -CHECK &&I ASM &SRC
  593.   &COMMAND COPYFILE &&I ASM &FM KERMIT ASSEMBLE &DISK5 ( ©OP
  594.   ©OP = &STRING OF APPEND
  595. -MAKEND
  596. *
  597. *-------------- ************ S T E P   BWR 4
  598. *
  599. *----------------------------------- FAN OUT UPDATE FILES
  600. &COMMAND VMFCLEAR
  601. &COMMAND ESTATE KERMIT AUXOPT *
  602. &AUXOPT = &RC
  603. &CALL -ASK LCL  Any local updates to apply
  604. &IF &LCL EQ NO &SKIP 2
  605.   &IF &AUXOPT NE 0 &CALL -CHECK KERMIT LOCAL *
  606.   &SKIP 1
  607.     &IF &AUXOPT EQ 0 &PRINT *** Warning: 'KERMIT AUXOPT' exists anyway.
  608. &COMMAND ESTATE KERMIT AUXLCL &DISK
  609. &IF &RC EQ 0 &CALL -ASK FAN  Re-extract individual update files
  610. &IF &FAN EQ NO &GOTO -FANEND
  611. &PRINT Extracting individual update files
  612. &COMMAND XEDIT IKCKER UPD * ( PROFILE IKCFAN ) &DISK
  613. &IF &XA EQ YES &COMMAND XEDIT IKCXA UPD * ( PROFILE IKCFAN ) &DISK
  614. *
  615. *-------------- ************ S T E P   BWR 5
  616. *
  617. &COMMAND ESTATE IKCKER NUP *
  618. &IF &RC NE 0 &SKIP 2
  619.   &CALL -ASK FAN  Extract updates from IKCKER NUP
  620.   &IF &FAN EQ YES &COMMAND XEDIT IKCKER NUP * ( PROFILE IKCFAN ) &DISK
  621. &IF &LCL EQ NO &SKIP 2
  622.   &COMMAND ESTATE KERMIT LOCAL *
  623.   &IF &RC EQ 0 &COMMAND XEDIT KERMIT LOCAL * ( PROFILE IKCFAN ) &DISK
  624. -FANEND
  625. *------------------- ONE LAST CHECK: CNTRL FILE FROM FAN
  626. &CALL -CHECK &CNTRL CNTRL &DISK
  627. &IF &LCL EQ YES &CALL -CHECK KERMIT AUXOPT *
  628. *
  629. *-------------- ************ S T E P   INS 3
  630. *
  631. *----------------------------------------- MAKE HELP FILE
  632. -MAKEHELP
  633. &CALL -GETPARM HELPFT  filetype  help filetype
  634. &COMMAND ESTATE KERMIT &HELPFT &DISK
  635. &IF &RC EQ 0 &CALL -ASK HELP  HELP file already on disk &DISK - replace it
  636. &IF &HELP EQ NO &GOTO -HELPEND
  637. &CALL -CHECK IKCKER HLP &SRC
  638. &IF &LVL GE 3 &SKIP 2
  639.   &COMMAND COPYFILE IKCKER HLP &FM KERMIT &HELPFT &DISK2 (REP
  640.   &GOTO -HELPEND
  641. &COMMAND HELPCONV IKCKER HLP &FM
  642. &CALL -ASK PDS  Convert help file to PDS form
  643. &IF &PDS EQ YES &SKIP 2
  644.   &COMMAND COPYFILE IKCKER $HLP A KERMIT &HELPFT &DISK2 (REP
  645.   &GOTO -HELPEND
  646. &CALL -ASK PDS  Remove confusing help section separators
  647. &COMMAND VMFCLEAR
  648. &PRINT Installing KERMIT &HELPFT ...
  649. &COMMAND MAKEBUF
  650. &BUFNO = &RC
  651. &STACK FIFO SET MSGMODE OFF
  652. &STACK FIFO SET RECFM F
  653. &STACK FIFO SET CASE M
  654. * WARNING: THERE ARE LOWER-CASE CHARACTERS IN 2 OF THE NEXT 4 LINES
  655. &IF &PDS EQ NO &SKIP 2
  656.   &STACK FIFO LOCATE -2/.cs / DEL
  657.   &STACK FIFO REPEAT *
  658. &STACK FIFO :0 C/.cm /*COPY /*
  659. &STACK FIFO SET MSGMODE ON
  660. &STACK FIFO FFILE TEMPKERM COPY &DISK5
  661. &COMMAND XEDIT IKCKER $HLP (NOPROF
  662. &COMMAND DROPBUF &BUFNO
  663. &COMMAND MACLIB GEN TEMPKERM TEMPKERM
  664. &COMMAND COPYFILE TEMPKERM MACLIB A KERMIT &HELPFT &DISK2 (REP
  665. &COMMAND ERASE TEMPKERM MACLIB A
  666. &COMMAND ERASE TEMPKERM COPY &DISK
  667. -HELPEND
  668. &IF &LVL LE 3 &GOTO -MENUEND
  669. &CALL -ASK MENU  Create HELP menu system
  670. &IF &MENU EQ NO &GOTO -MENUEND
  671. &COMMAND ESTATE IKCKER $HLP A
  672. &IF &RC EQ 0 &SKIP 2
  673.   &CALL -CHECK IKCKER HLP &SRC
  674.   &COMMAND HELPCONV IKCKER HLP &FM
  675. &PRINT Installing KER HELPTASK ...
  676. &COMMAND MAKEBUF
  677. &BUFNO = &RC
  678. &STACK FIFO SET MSGMODE OFF
  679. &STACK FIFO SET CASE M
  680. &STACK FIFO SET ARBCHAR ON $
  681. * WARNING: THERE ARE LOWER-CASE CHARACTERS IN THE NEXT LINE
  682. &STACK FIFO :0 C/.cm $ /:READ $ &HELPFT /*
  683. &STACK FIFO SET MSGMODE ON
  684. &STACK FIFO FFILE TEMPKERM HELP &DISK2
  685. &COMMAND XEDIT IKCKER $HLP (NOPROF
  686. &COMMAND DROPBUF &BUFNO
  687. &COMMAND ERASE SETCOM HELPTASK &DISK
  688. &COMMAND XEDIT TEMPKERM HELP &DISK2 ( PROFILE IKCMENU
  689. &COMMAND XEDIT TEMPKERM HELP &DISK2 ( PROFILE IKCFAN ) &DISK2
  690. &COMMAND ERASE TEMPKERM HELP &DISK
  691. -MENUEND
  692. &COMMAND ERASE IKCKER $HLP A
  693. &IF &HELPONLY EQ YES &EXIT
  694. *
  695. *-------------- ************ S T E P   BWR 6
  696. *
  697. *----------------------------------------- APPLY UPDATES
  698. &COMMAND ERASE $KERMIT ASSEMBLE &DISK
  699. &COMMAND ERASE KERMIT TEXT &DISK
  700. &PRINT Updating KERMIT ASSEMBLE
  701. &DQ = &CONCAT OF &DISK '
  702. &PRINT File 'KERMIT UPDATES &DQ will have the list of updates applied...
  703. &IF &UPDMSG EQ NO &COMMAND SET CMSTYPE HT
  704. &UPDOPTS = &STRING OF CTL STK OUTMODE &DISK PRINT INC
  705. &COMMAND UPDATE KERMIT ASSEMBLE &DISK &CNTRL CNTRL &DISK ( &UPDOPTS
  706. &UPDRC = &RC
  707. &COMMAND SET CMSTYPE RT
  708. &IF &UPDRC GT 12 &GOTO -ERR3
  709. *
  710. *-------------- ************ S T E P   INS 4
  711. *
  712. *------------------------------- RETRIEVE MACLIB LIST FROM STACK
  713. &COMMAND SENTRIES
  714. &IF &RC LE 1 &GOTO -ERR3
  715. &READ VARS
  716. &READ ARGS
  717. &IF &N LE 1 &GOTO -ERR3
  718. &MACLIBS = &RANGE OF & 2 9
  719. &COMMAND GLOBAL MACLIB &MACLIBS
  720. *
  721. *-------------- ************ S T E P   INS 5
  722. *
  723. *----------------------------------------------- ASSEMBLE KERMIT
  724. &PRINT Assembling...
  725. &NAME = KERMIT
  726. &COMMAND &ASMCMD $KERMIT ( NOESD NORLD PRINT &ASMOPTS
  727. &IF &RC NE 0 &GOTO -ERR4
  728. &COMMAND ERASE $KERMIT ASSEMBLE &DISK
  729. &COMMAND RENAME $KERMIT TEXT &DISK KERMIT = &DISK2
  730. &LOADS = KERMIT
  731. &IF &ACT EQ NO &SKIP 4
  732.   &LOADS = &STRING OF &LOADS KACCT
  733.   &NAME = KACCT
  734.   &COMMAND &ASMCMD KACCT ( NOESD NORLD PRINT &ASMOPTS
  735.   &IF &RC NE 0 &GOTO -ERR4
  736. &IF &BOOT EQ NO &SKIP 4
  737.   &LOADS = KERMBOOT
  738.   &NAME = KERMBOOT
  739.   &COMMAND &ASMCMD KERMBOOT ( NOESD NORLD PRINT &ASMOPTS
  740.   &IF &RC NE 0 &GOTO -ERR4
  741. &COMMAND CP CLOSE 00E NA KERMIT LISTING
  742. *
  743. *-------------- ************ S T E P   INS 6
  744. *
  745. &PRINT Loading Kermit ...
  746. &IF &LVL GE 3 &RLDSAVE = RLDSAVE
  747. &COMMAND LOAD &LOADS (CLEAR NOMAP &RLDSAVE
  748. &R = &RC
  749. &COMMAND GENMOD KERMIT MODULE &DISK2
  750. &IF &RC GT &R &R = &RC
  751. &IF &R EQ 0 &IF &PRKEEP EQ NO &SKIP 1
  752.   &COMMAND CP SPOOL 00E CLOSE
  753. &COMMAND CP SPOOL 00E PURGE &SPCONT &SPTO
  754. &EXIT &RC
  755. *-------------------------------------------------------------------
  756. *-------------------------------------- CONFIRM EXISTENCE OF A FILE
  757. -CHECK
  758. &COMMAND ESTATE &1 &2 &3
  759. &IF &RC EQ 0 &SKIP 3
  760.   &X = &CONCAT OF &3 '
  761.   &PRINT File '&1 &2 &X not found.
  762.   &GOTO -DONE
  763. &FM = &3
  764. &IF .&3 NE .* &RETURN
  765. &COMMAND MAKEBUF
  766. &COMMAND LISTFILE &1 &2 &3 (FIFO
  767. &READ VARS * * &FM
  768. &COMMAND DROPBUF
  769. &RETURN
  770. *----------------------------------- ASK FOR POSSIBLE OVERRIDE (PARM)
  771. -GETPARM &X = &CONCAT OF ' &&1 '
  772. &MSGTXT = &RANGE OF & 3 &N
  773. &PRINT Default &MSGTXT is &X - enter alternate &2 if desired:
  774. -GETPM1 &IF &1 EQ ASMCMD &SKIP 2
  775.   &READ VAR &NEW
  776.   &SKIP 1
  777.     &READ STRING &NEW
  778. &IF .&NEW NE .* &SKIP 2
  779.   &PRINT '*' not allowed, except as default.  Re-enter, or type STOP:
  780.   &GOTO -GETPM1
  781. &IF .&NEW EQ .STOP &GOTO -QUIT
  782. &IF .&NEW NE . &&1 = &NEW
  783. &RETURN
  784. *----------------------------------- ASK FOR POSSIBLE OVERRIDE (YES/NO)
  785. -ASK &MSG = &RANGE OF & 2 &N
  786. &DEFMSG = &CONCAT OF (default: &BLANK &&1 )?
  787.   &PRINT &MSG &DEFMSG
  788.   &READ VAR &NEWVAL
  789.   &X = &POSITION OF .&NEWVAL .  .Y .YES .N .NO .STOP
  790. &IF &X EQ 0 &SKIP -3
  791. &IF .&NEWVAL EQ .STOP &GOTO -QUIT
  792. &&1    = &WORD OF           &&1 YES YES NO  NO  ...  &X
  793. &RETURN
  794. *-------------------------------------- ERROR EXITS
  795. -QUIT &PRINT Stopping...
  796.    &GOTO -DONE
  797. -ERR1 &PRINT &0 would destroy $KERMIT ASSEMBLE &DISK
  798.    &GOTO -DONE
  799. -ERR2 &PRINT Mode letter &disk not defined
  800.    &GOTO -DONE
  801. -ERR3 &PRINT Error in UPDATE - rc=&UPDRC
  802.    &IF &UPDRC NE 0 &PRINT Enter 'HELP UPDATE' for explanation.
  803.    &GOTO -DONE
  804. -ERR4 &PRINT Error in assembling &NAME - rc=&RC
  805.    &GOTO -DONE
  806. -ERR5 &FID = &CONCAT OF 'KERMIT &BLANK TEXT &BLANK &TXTDSK '
  807.    &PRINT &FID precedes disk &DISK in search order.
  808.    &PRINT Remove or rename.
  809. -DONE
  810.    &COMMAND CP CLOSE 00E NA KERMIT LISTING
  811.    &COMMAND CP SPOOL 00E CLOSE
  812.    &COMMAND CP SPOOL 00E &SPCONT &SPTO
  813.    &EXIT 100
  814.